﻿using System;

namespace WiMo.Games.StandardInput.Accelerometer
{
    public static class GSensorFactory
    {
        public static IGSensor CreateGSensor()
        {
            // Try the Samsung one first so it doesn't pick up the HTC accelerometer emulator
            try
            {
                return SamsungGSensor.Create();
            }
            catch (Exception)
            {
            }
            try
            {
                return HTCGSensor.Create();
            }
            catch (Exception)
            {
            }
            return null;
        }
    }
}
